﻿using System.ComponentModel.DataAnnotations;

namespace Sharp.WebBooter.Areas.CMS.Models
{

    public class LoginViewModel
    {

        [Required]
        [Display(Name = "用户名", Prompt = "用户名或者电子邮件")]

        public string Name { get; set; }

        [Required]
        [DataType(DataType.Password)]
        [Display(Name = "密码", Prompt = "密码")]
        public string Password { get; set; }

        [Display(Name = "记住登录")]
        public bool RememberMe { get; set; }

        [Display(Name = "验证码", Prompt = "验证码")]
        public string ValidateCode { get; set; }
    }

    public class ForgotPasswordViewModel
    {
        [Required]
        [EmailAddress]
        [Display(Name = "预留的邮箱", Prompt = "请输入预留的邮箱")]
        public string Email { get; set; }
        /// <summary>
        /// 消息
        /// </summary>
        public string Message { get; set; }
    }

    /// <summary>
    /// 修改密码视图模型
    /// </summary>
    public class ChangePassword
    {
        /// <summary>
        /// 获取或设置当前客户的登录密码。
        /// </summary>
        [Display(Name = "密码"), Required]
        public string Password { get; set; }

        /// <summary>
        /// 用户设置新的登录密码
        /// </summary>
        [Display(Name = "新密码"), Compare("PasswordNewS")]
        public string PasswordNew { get; set; }
        /// <summary>
        /// 用户重新输入新密码输入新密码
        /// </summary>
        [Display(Name = "重新输入新密码"), Compare("PasswordNew")]
        public string PasswordNewS { get; set; }
    }
}
